package cn.wolfcode.cloud.shop.common;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import java.io.Serializable;

@Setter
@Getter
@NoArgsConstructor
public class CodeMsg implements Serializable {
    public final static CodeMsg DEFAULT_ERROR = new CodeMsg(500, "服务器正忙，请稍后再试.");
    // 异常状态码
    private int code;
    // 异常信息
    private String msg;

    public CodeMsg(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}